<template>
    <div class="content">
        <div class="about-right">
            <div class="about-item">
                <div class="about-item-left">
                    <div class="item-text">
                        <p>
                            <router-link to="/" v-for="item in centerpiseData" :key="item.name">{{ item.name
                            }}</router-link>
                        </p>
                    </div>
                </div>
            </div>
        </div>
    </div>
</template>
<script setup lang="ts">
import { enterpriseListApi } from "../../api/work/work";
import type { EnterpriseModel } from "../../api/work/work";
const centerpiseData = ref<EnterpriseModel[]>([])
import { cloneDeep } from 'lodash'
onMounted(async () => {
    const res = await enterpriseListApi()
    if (res.code === 200) {
        centerpiseData.value = cloneDeep(res.data) ?? []
    } else {
        ElMessage.error(res.msg)
    }
})
</script>
<style scoped lang='less'>
.content {
    width: calc(100% - 220px);
    // background-color: red;
    height: 100%;

}

a {
    text-decoration: none;
}

.item-text {
    padding-top: 20px;
}

p {
    font-size: 15px;
    font-weight: 400;
    color: #434343;
    line-height: 40px;
}

.item-text a {
    margin: 10px 40px;
    font-size: 16px;
    border: 1px solid #eee;
    border-radius: 5px;
    padding: 0px 30px;
    white-space: nowrap;
    display: inline-block;
    color: #000;
    width: 350px;
}</style>
